package club.banyuan;

import java.util.ArrayList;
import java.util.List;

public class Main {
    public static void main(String[] args) {
        Team team = new Team();
        Player player1 = new Player("库里",30,"PG");
        Player player2 = new Player("汤普森",11,"SG");
        Player player3 = new Player("维金斯",22,"SF");
        Player player4 = new Player("格林",23,"PF");
        Player player5 = new Player("卢尼",5,"C");
        team.getStarting().add(player1);
        team.getStarting().add(player2);
        team.getStarting().add(player3);
        team.getStarting().add(player4);
        team.getStarting().add(player5);

        Player player6 = new Player("姚明",13,"C");
        Player player7 = new Player("易建联",11,"PF");
        Player player8 = new Player("朱芳雨",8,"SF");
        Player player9 = new Player("孙悦",8,"PG");
        Player player10 = new Player("陈江华",4,"SG");
        team.getSubstitute().add(player6);
        team.getSubstitute().add(player7);
        team.getSubstitute().add(player8);
        team.getSubstitute().add(player9);
        team.getSubstitute().add(player10);

        System.out.println(team);
        System.out.println("--------------------");

        team.Replace(player6);
        team.Replace(player7);
        System.out.println(team);
        System.out.println("--------------------");

        team.addToSubstitute(new Player("刘炜",5,"PG"));
        System.out.println(team);
        System.out.println("--------------------");

        List<Player> newList = new ArrayList<>();
        newList.add(player8);
        newList.add(player9);
        newList.add(player10);
        team.adjust(newList);
        System.out.println(team);
        System.out.println("--------------------");

        team.deletePlayer(player5);
        System.out.println(team);
        System.out.println("--------------------");

    }
}
